// test.cpp : 定义控制台应用程序的入口点。
//

#include "stdafx.h"
#include <string>
#include <vector>
#include <iostream>
#include <fstream>

#include "tool_th.h"

using namespace tool_th;
int main()
{
    /*
	std::map<std::string, std::string> request_headers;
	request_headers["Host"] = "www.baidu.com";
	request_headers["User-Agent"] ="Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.111 Safari/537.36";
	request_headers["Accept-Encoding"] ="gzip, deflate, sdch";

	myhttp aaa;

	aaa.init("https://www.baidu.com",request_headers);
	aaa.gethtml();
	aaa.printReuslt(false,"aaa.txt","bbb.txt");
	*/
	std::string str ="http://www.baidu.com";
	std::string user,pass,host,port,path;
	bool is_https;
	parseURL(str,user,pass,host,port,path,is_https);
	system("pause");
	return 0;
}
